<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Eigen: Eigen::IndexedView&lt; XprType, RowIndices, ColIndices &gt; Class Template Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  $(document).ready(function() { init_search(); });
/* @license-end */
</script>
<script type="text/x-mathjax-config">
  MathJax.Hub.Config({
    extensions: ["tex2jax.js", "TeX/AMSmath.js", "TeX/AMSsymbols.js"],
    jax: ["input/TeX","output/HTML-CSS"],
});
</script>
<script type="text/javascript" async="async" src="https://cdn.mathjax.org/mathjax/latest/MathJax.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="eigendoxy.css" rel="stylesheet" type="text/css">
<!--  -->
<script type="text/javascript" src="eigen_navtree_hacks.js"></script>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="Eigen_Silly_Professor_64x64.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname"><a href="http://eigen.tuxfamily.org">Eigen</a>
   &#160;<span id="projectnumber">3.4.90 (git rev 67eeba6e720c5745abc77ae6c92ce0a44aa7b7ae)</span>
   </div>
  </td>
   <td>        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.svg"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.svg" alt=""/></a>
          </span>
        </div>
</td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('classEigen_1_1IndexedView.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="classEigen_1_1IndexedView-members.html">List of all members</a> &#124;
<a href="#pub-methods">Public Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">Eigen::IndexedView&lt; XprType, RowIndices, ColIndices &gt; Class Template Reference<div class="ingroups"><a class="el" href="group__DenseMatrixManipulation__chapter.html">Dense matrix and array manipulation</a> &raquo; <a class="el" href="group__DenseMatrixManipulation__Reference.html">Reference</a> &raquo; <a class="el" href="group__Core__Module.html">Core module</a></div></div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><h3>template&lt;typename XprType, typename RowIndices, typename ColIndices&gt;<br />
class Eigen::IndexedView&lt; XprType, RowIndices, ColIndices &gt;</h3>

<p>Expression of a non-sequential sub-matrix defined by arbitrary sequences of row and column indices. </p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">XprType</td><td>the type of the expression in which we are taking the intersections of sub-rows and sub-columns </td></tr>
    <tr><td class="paramname">RowIndices</td><td>the type of the object defining the sequence of row indices </td></tr>
    <tr><td class="paramname">ColIndices</td><td>the type of the object defining the sequence of column indices</td></tr>
  </table>
  </dd>
</dl>
<p>This class represents an expression of a sub-matrix (or sub-vector) defined as the intersection of sub-sets of rows and columns, that are themself defined by generic sequences of row indices \( \{r_0,r_1,..r_{m-1}\} \) and column indices \( \{c_0,c_1,..c_{n-1} \}\). Let \( A \) be the nested matrix, then the resulting matrix \( B \) has <code>m</code> rows and <code>n</code> columns, and its entries are given by: \( B(i,j) = A(r_i,c_j) \).</p>
<p>The <code>RowIndices</code> and <code>ColIndices</code> types must be compatible with the following API: </p><div class="fragment"><div class="line">&lt;integral type&gt; operator[](<a class="code" href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Index</a>) <span class="keyword">const</span>;</div>
<div class="line"><a class="code" href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Index</a> size() <span class="keyword">const</span>;</div>
<div class="ttc" id="anamespaceEigen_html_a62e77e0933482dafde8fe197d9a2cfde"><div class="ttname"><a href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Eigen::Index</a></div><div class="ttdeci">EIGEN_DEFAULT_DENSE_INDEX_TYPE Index</div><div class="ttdoc">The Index type as used for the API.</div><div class="ttdef"><b>Definition:</b> Meta.h:59</div></div>
</div><!-- fragment --><p>Typical supported types thus include:</p><ul>
<li>std::vector&lt;int&gt;</li>
<li>std::valarray&lt;int&gt;</li>
<li>std::array&lt;int&gt;</li>
<li>Plain C arrays: int[N]</li>
<li>Eigen::ArrayXi</li>
<li>decltype(ArrayXi::LinSpaced(...))</li>
<li>Any view/expressions of the previous types</li>
<li><a class="el" href="classEigen_1_1ArithmeticSequence.html">Eigen::ArithmeticSequence</a></li>
<li>Eigen::internal::AllRange (helper for Eigen::placeholders::all)</li>
<li>Eigen::internal::SingleRange (helper for single index)</li>
<li>etc.</li>
</ul>
<p>In typical usages of Eigen, this class should never be used directly. It is the return type of DenseBase::operator()(const RowIndices&amp;, const ColIndices&amp;).</p>
<dl class="section see"><dt>See also</dt><dd>class <a class="el" href="classEigen_1_1Block.html" title="Expression of a fixed-size or dynamic-size block.">Block</a> </dd></dl>
</div>
<p>Inherits Eigen::IndexedViewImpl&lt; XprType, RowIndices, ColIndices, internal::traits&lt; XprType &gt;::StorageKind &gt;.</p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:ae4abc26fe04506a02d49e704e112f5bf"><td class="memItemLeft" align="right" valign="top">const ColIndices &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1IndexedView.html#ae4abc26fe04506a02d49e704e112f5bf">colIndices</a> () const</td></tr>
<tr class="separator:ae4abc26fe04506a02d49e704e112f5bf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6d5f355dd721df6d39482a04e5ffd44d"><td class="memItemLeft" align="right" valign="top"><a class="el" href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Index</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1IndexedView.html#a6d5f355dd721df6d39482a04e5ffd44d">cols</a> () const</td></tr>
<tr class="separator:a6d5f355dd721df6d39482a04e5ffd44d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac5dc9667c0f8a146b83e1a5fd62bbe68"><td class="memItemLeft" align="right" valign="top">std::remove_reference_t&lt; XprType &gt; &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1IndexedView.html#ac5dc9667c0f8a146b83e1a5fd62bbe68">nestedExpression</a> ()</td></tr>
<tr class="separator:ac5dc9667c0f8a146b83e1a5fd62bbe68"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6afbd76c81c5c53736625ad96f371009"><td class="memItemLeft" align="right" valign="top">const internal::remove_all_t&lt; XprType &gt; &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1IndexedView.html#a6afbd76c81c5c53736625ad96f371009">nestedExpression</a> () const</td></tr>
<tr class="separator:a6afbd76c81c5c53736625ad96f371009"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af038f6d19de286c0b959f3c1b8daa20d"><td class="memItemLeft" align="right" valign="top">const RowIndices &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1IndexedView.html#af038f6d19de286c0b959f3c1b8daa20d">rowIndices</a> () const</td></tr>
<tr class="separator:af038f6d19de286c0b959f3c1b8daa20d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae0d840059e7753d58f3de53da7d04ce0"><td class="memItemLeft" align="right" valign="top"><a class="el" href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Index</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1IndexedView.html#ae0d840059e7753d58f3de53da7d04ce0">rows</a> () const</td></tr>
<tr class="separator:ae0d840059e7753d58f3de53da7d04ce0"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="ae4abc26fe04506a02d49e704e112f5bf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae4abc26fe04506a02d49e704e112f5bf">&#9670;&nbsp;</a></span>colIndices()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename XprType , typename RowIndices , typename ColIndices &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">const ColIndices&amp; <a class="el" href="classEigen_1_1IndexedView.html">Eigen::IndexedView</a>&lt; XprType, RowIndices, ColIndices &gt;::colIndices </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="section return"><dt>Returns</dt><dd>a const reference to the object storing/generating the column indices </dd></dl>

</div>
</div>
<a id="a6d5f355dd721df6d39482a04e5ffd44d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6d5f355dd721df6d39482a04e5ffd44d">&#9670;&nbsp;</a></span>cols()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename XprType , typename RowIndices , typename ColIndices &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Index</a> <a class="el" href="classEigen_1_1IndexedView.html">Eigen::IndexedView</a>&lt; XprType, RowIndices, ColIndices &gt;::cols </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="section return"><dt>Returns</dt><dd>number of columns </dd></dl>

</div>
</div>
<a id="ac5dc9667c0f8a146b83e1a5fd62bbe68"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac5dc9667c0f8a146b83e1a5fd62bbe68">&#9670;&nbsp;</a></span>nestedExpression() <span class="overload">[1/2]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename XprType , typename RowIndices , typename ColIndices &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">std::remove_reference_t&lt;XprType&gt;&amp; <a class="el" href="classEigen_1_1IndexedView.html">Eigen::IndexedView</a>&lt; XprType, RowIndices, ColIndices &gt;::nestedExpression </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="section return"><dt>Returns</dt><dd>the nested expression </dd></dl>

</div>
</div>
<a id="a6afbd76c81c5c53736625ad96f371009"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6afbd76c81c5c53736625ad96f371009">&#9670;&nbsp;</a></span>nestedExpression() <span class="overload">[2/2]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename XprType , typename RowIndices , typename ColIndices &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">const internal::remove_all_t&lt;XprType&gt;&amp; <a class="el" href="classEigen_1_1IndexedView.html">Eigen::IndexedView</a>&lt; XprType, RowIndices, ColIndices &gt;::nestedExpression </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="section return"><dt>Returns</dt><dd>the nested expression </dd></dl>

</div>
</div>
<a id="af038f6d19de286c0b959f3c1b8daa20d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af038f6d19de286c0b959f3c1b8daa20d">&#9670;&nbsp;</a></span>rowIndices()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename XprType , typename RowIndices , typename ColIndices &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">const RowIndices&amp; <a class="el" href="classEigen_1_1IndexedView.html">Eigen::IndexedView</a>&lt; XprType, RowIndices, ColIndices &gt;::rowIndices </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="section return"><dt>Returns</dt><dd>a const reference to the object storing/generating the row indices </dd></dl>

</div>
</div>
<a id="ae0d840059e7753d58f3de53da7d04ce0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae0d840059e7753d58f3de53da7d04ce0">&#9670;&nbsp;</a></span>rows()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename XprType , typename RowIndices , typename ColIndices &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Index</a> <a class="el" href="classEigen_1_1IndexedView.html">Eigen::IndexedView</a>&lt; XprType, RowIndices, ColIndices &gt;::rows </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="section return"><dt>Returns</dt><dd>number of rows </dd></dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="IndexedView_8h_source.html">IndexedView.h</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="namespaceEigen.html">Eigen</a></li><li class="navelem"><a class="el" href="classEigen_1_1IndexedView.html">IndexedView</a></li>
    <li class="footer">Generated on Thu Apr 21 2022 13:07:56 for Eigen by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.9.1 </li>
  </ul>
</div>
</body>
</html>
